package com.tidc.provider8001.controller;

import com.tidc.provider8001.service.TestService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

/**
 * @ClassNmae Controller
 * @Description TODO
 * @Author 14631
 **/
@RestController
public class Controller {
	@Autowired
	TestService testService;
	@GetMapping("/test/{id}")
//	@hystrixCommd(里面是方法名 这个是方法出异常以后执行哪个方法)
	public String test(@PathVariable("id") int id){

		return testService.test(id);
	}
}
